import { Big } from "../core/Big";
import { Point, Terrain } from "../core/Point";
import Utils from "../GameUtils";

export class 拳师 extends Big {

    markPoint:Point = null     //怒威神拳攻击成功后给敌方大子father的标记

    addMark(big: Big) {
        this.markPoint = big.point
        this.gameMgr.sendBroadcast(Utils.getObj("update_拳师_mark",{"start":this.point.id, "end":this.markPoint.id},true,false),false)
    }

    removeMark() {
        this.markPoint = null
        this.gameMgr.sendBroadcast(Utils.getObj("remove_拳师_mark",{"start":this.point.id},true,false),false)
    }

    terrainAdapt() {
        switch (this.point.terrain) {
            case Terrain.SHAN:
            case Terrain.SHUI:
                this.die(this.player)
        }
    }
}